<div class="example-container">
  <mat-form-field>
    <mat-label>Enter your email</mat-label>
    <input
      matInput
      placeholder="pat@example.com"
      [formControl]="email"
      (blur)="updateErrorMessage()"
      required
    />
    @if (email.invalid) {
      <mat-error>{{errorMessage()}}</mat-error>
    }
  </mat-form-field>
</div>
